package com.wei.czz.common.vo.annex;

import com.wei.czz.common.jsr303.group.Save;
import com.wei.czz.common.jsr303.group.Update;
import com.wei.czz.common.tool.BaseEntity;
import lombok.Getter;
import lombok.Setter;

import javax.validation.constraints.NotBlank;
import javax.validation.constraints.NotNull;
import java.math.BigDecimal;
import java.time.LocalDate;
import java.time.LocalDateTime;
import java.util.List;

/**
 * Created by IntelliJ IDEA.
 *
 * @author wyw
 * date: 2024-01-18 17:49:54
 * className: AnnexConfigConditionVo
 * version: 1.0
 * description:
 */
@Getter
@Setter
public class AnnexConfigConditionVo extends BaseEntity {

    /**
     * 值
     */
    @NotNull(message = "字段条件值不能为空", groups = { Save.class, Update.class })
    private Integer value;

    /**
     * 值名称
     */
    private String valueName;

    /**
     * 比较方式
     */
    @NotNull(message = "字段条件比较方式不能为空", groups = { Save.class, Update.class })
    private Integer compareMode;

    /**
     * 比较方式名称
     */
    private String compareModeName;

    /**
     * 数值
     */
    private BigDecimal equalsNumber;

    /**
     * 字符串值
     */
    private String equalsString;

    /**
     * 数值列表
     */
    private List<BigDecimal> numberList;

    /**
     * 匹配字符串值
     */
    private String containString;

    /**
     * 数值范围-最小值
     */
    private BigDecimal minNumber;

    /**
     * 数值范围-最大值
     */
    private BigDecimal maxNumber;

    /**
     * 时间范围-最小值
     */
    private LocalDateTime minDateTime;

    /**
     * 时间范围-最大值
     */
    private LocalDateTime maxDateTime;

    /**
     * 日期范围-最小值
     */
    private LocalDate minDate;

    /**
     * 日期范围-最大值
     */
    private LocalDate maxDate;

    /**
     * 显示的值
     */
    @NotBlank(message = "字段条件值不能为空", groups = { Save.class, Update.class })
    private String showValue;

}
